package com.binance.notification.api.push;

import com.binance.master.commons.ToString;
import com.binance.master.validator.constraints.CustomCheck;
import com.binance.notification.verifier.PushCommandVerifier;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import java.util.ArrayList;
import java.util.List;

@ApiModel(value = "推送控制命令", description = "推送控制命令，users和targetUserType不能同时使用。")
@CustomCheck(verifier = PushCommandVerifier.class)
@Setter
@Getter
public class PushCommand extends ToString {

    private static final long serialVersionUID = -3157233443007899176L;
    @ApiModelProperty(value = "指定的用户ID的集合，与targetUserKey不能同时使用", required = false)
    private final List<String> users = new ArrayList<>();
    @ApiModelProperty(value = "离线保存秒数")
    private long timeToLive;
    @ApiModelProperty(value = "目标用户存在于redis中的键，与users不能同时使用", required = false)
    private String targetUserKey;
    @ApiModelProperty(value = "标签OR")
    private List<String> tags;
    @ApiModelProperty(value = "标签NOT")
    private List<String> tagNotList;
    @ApiModelProperty(value = "标签AND")
    private List<String> tagAndList;

}
